<template>
  <div>
    <svg-icon icon-class="fullscreen" @click="fullScreen" />
  </div>
</template>
<script>
import screenFull from 'screenfull'
export default {
  name: 'ScreenFull',
  methods: {
    fullScreen() {
      if (screenFull.isEnabled) {
        console.log(screenFull)
        screenFull.toggle()
      } else {
        this.$message.error('当前浏览器不支持全屏')
      }
    }
  }
}
</script>
<style scoped lang="scss"></style>
